﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="middle.aspx.cs" Inherits="middle" MasterPageFile="~/MasterPage.master" %>

<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<%@ OutputCache Duration="60" VaryByParam="*" %>
<asp:Content ID="header" ContentPlaceHolderID="HeaderStyle" runat="server">
    <style type="text/css">
        .tableleft {
            float: left;
        }

        .tableright {
            float: right;
        }
        .clear {
         clear:both;
        }
        .ksfl {
        font-size: small; margin-top: 10px;
        }
    </style>
</asp:Content>
<asp:Content ID="main" ContentPlaceHolderID="main" runat="server">
    <div class="row">
        <div class="col-md-3 bs-docs-sidebar">
            <div class="panel panel-primary ">
                <div class="panel-heading">
                    <h3 class="panel-title">法律文集</h3>
                </div>
                <div class="panel-body">
                    <ul class="nav nav-pills nav-stacked">
                        <li role="presentation" class="active"><a href="middle.aspx?ID=1">律师文集</a></li>
                        <li role="presentation"><a href="middle.aspx?ID=2">案例分析</a></li>
                        <li role="presentation"><a href="middle.aspx?ID=3">法律解答</a></li>
                        <li role="presentation"><a href="middle.aspx?ID=4">律师实务</a></li>
                    </ul>
                </div>
            </div>
        </div>
        <div class="col-md-9">
            <div class="panel panel-primary">
                <div class="panel-heading" style="padding: 5px;">
                    <ol class="breadcrumb" style="margin: 0px;">
                        <li><a href="Default.aspx">首页</a></li>
                        <li class="active"><%=GetClass() %></li>
                    </ol>
                </div>
                <div class="panel-body">

                    <table class="table table-striped">
                        <tbody>
                            <asp:Repeater ID="Repeater1" runat="server" OnItemDataBound="Repeater1_ItemDataBound" OnItemCommand="Repeater1_ItemCommand">
                                <ItemTemplate>
                                    <tr>
                                        <td>
                                            <div class="tableleft"><strong><a href="TopicView.aspx?ID=<%#Eval("ID") %>"><%#Eval("TopicTitle") %></a></strong></div>
                                            <div class="tableright"><%#Eval("TopicTime") %></div>
                                            <div  class="clear" ></div>
                                            <div  class="ksfl" >分类：<a href="middle.aspx?ID=<%#Eval("TopicClass") %>"><asp:Literal ID="textClass" runat="server" Text='<%#Eval("TopicClass") %>'></asp:Literal></a> | <span>浏览：<%#Eval("TopicLookNum") %></span></div>
                                        </td>
                                    </tr>
                                </ItemTemplate>
                                <FooterTemplate>
                                    <asp:Literal ID="lblEmpty" runat="server" Text="当前没有任何数据！" Visible='<%#bool.Parse((Repeater1.Items.Count==0).ToString())%>'></asp:Literal>
                                </FooterTemplate>
                            </asp:Repeater>
                        </tbody>
                    </table>
                    <webdiyer:AspNetPager ID="AspNetPager1" CurrentPageButtonClass="" runat="server"
                        FirstPageText="首页" LastPageText="尾页" NextPageText="下一页" PrevPageText="上一页" ShowCustomInfoSection="Left"
                        ShowInputBox="Never" OnPageChanged="AspNetPager1_PageChanged" CustomInfoTextAlign="Left" LayoutType="Table" UrlPaging="True" CustomInfoHTML="总页 %CurrentPageIndex% / %PageCount%">
                    </webdiyer:AspNetPager>
                </div>
            </div>
        </div>
    </div>
</asp:Content>

<asp:Content ID="js" ContentPlaceHolderID="footerJS" runat="server">
    <script type="text/javascript">
        $(document).ready(function () {
            $(".panel-body").find("li").eq(<%=Num-1 %>).addClass("active").siblings().removeClass("active");
            $(".navbar-collapse").find("li").eq(<%=Num+1%>).addClass("active").siblings().removeClass("active");
        });
    </script>
</asp:Content>
